-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WIP] Add redux to dashboard state management #14103
[WIP] Add redux to dashboard state management #14103
Conversation
use real kibana version when creating panel data. Will make future conversions easier. Move default height and width to dashboard_constants so those that need it don't end up including extra stuff like ui/chrome
…, and handle case where destroyEmbeddable is not defined.
Had to implement this via code
Am not aware of a better way to handle this, aside from switching to redux, since it’s recommended not to put async calls in componentWillMount. Since I plan to investigate redux next, disabling for now. Open to other’s opinions on the matter.
@stacey-gammon First quick pass with the new react grid and it looks great!! A few questions, comments and potential bugs below. This seems to be specific to input controls but I can resize the panel and the visualization does not seem to adhere to the new dimensions. I recall you mentioning that the grid would be responsive so I checked it out with iPhone dimensions. I would have expected the panels to be force into one column rather than squishing two together at a certain point. Is this an expectation for the PR or out of scope? There seems to be an issue with region maps where sometimes the drop down appears when clicked and other times it did not Currently, the drop down can only be seen on edit mode. Most of the components here are specific to editing and deleting panels but are there any in which we'd need to surface this in view mode? Should we provide some default restrictions as far as size goes? Or do we just give users free range and allow them to make their own mistakes? I imagine small panels will be especially useful for metrics, etc. That's my first pass, hope this helps |
@alexfrancoeur -The PR you want is #13853, but your comments are relevant to that one as well, so I'll answer:
Known issue with input controls, this should be the case on master as well. #13982
I did not make it responsive intentionally. For the first switch over I wanted to get it to match the previous implementation as close as possible. Then we can focus on how the responsiveness should work in a separate PR. It is possible though.
Check out the PR above and let me know if it's still an issue. There was a problem with the drag event taking over the click event for the pop up which would annoying cause it to not pop up all the time. If it's still an issue I'll look into it.
Not yet, according to the design mocks:
Yea, I think we should let them make their own mistakes. Otherwise we are making assumptions on what is inside the panel. |
Closed in favor of #14199 |
This is built off the gridster -> react-grid-layout PR.
This is a work in progress, but here is a diagram of how the new redux/angular state management interacts. This is subject to change.
Angular UI is comprised of:
React UI is comprised of:
The redux store is created at the root of the Kibana app (
src/core_plugins/kibana/public/store.js
). Since we only want a single source of truth per app, and the core kibana app is made up of many sub apps (discover, visualize, dashboard, etc), these sub apps can use the store when they are ready to switch over.